// https://nuxt.com/docs/api/configuration/nuxt-config
export default defineNuxtConfig({
  compatibilityDate: "2024-11-01",
  devtools: { enabled: true },

  plugins: [
    { src: "~/plugins/element-plus.js", mode: "client" }, // 仅在客户端加载
  ],

  imports: {
    // 禁用自动导入
    // autoImport: false
    // 自动导入第三方包
    presets: [
      {
        from: "vue-i18n",
        imports: ["useI18n"],
      },
    ],
  },

  runtimeConfig: {
    // 只能在服务端获取的数据
    from: "服务端",

    // 服务端和客户端
    public: {
      baseUrl: "localhost:8080",
    },
  },
});
